﻿using Microsoft.EntityFrameworkCore;
using Paas.Pioneer.Admin.Core.Domain.Shared.Enum;
using Paas.Pioneer.Domain;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Paas.Pioneer.Admin.Core.Domain.Works.Info
{
    /// <summary>
    /// 作品表
    /// </summary>
    [Table("Works_Info")]
    [Comment("作品表")]
    [Index(nameof(UserId), Name = "IDX_UserId")]
    public class Works_InfoEntity : BaseEntity
    {
        /// <summary>
        /// 用户Id
        /// </summary>
        [Comment("用户Id")]
        [Column("UserId", TypeName = "char(36)")]
        public Guid UserId { get; set; }

        /// <summary>
        /// 标题
        /// </summary>
        [Comment("标题")]
        [Column("Title", TypeName = "varchar(500)")]
        public string Title { get; set; }

        /// <summary>
        /// 状态（1草稿，2发布）
        /// </summary>
        [Comment("状态")]
        [Column("WorksState", TypeName = "int")]
        public EWorksState WorksState { get; set; }

        /// <summary>
        /// 发布作品时用户位置
        /// </summary>
        [Comment("用户位置")]
        [Column("UserLocation", TypeName = "varchar(100)")]
        public string UserLocation { get; set; }
    }
}
